#![no_main]
#![no_std]

mod gpio;
mod pin;
mod uart;
mod dma;

use core::ops::Deref;

pub use gpio::*;
pub use pin::*;
use stm32f4::stm32f407::{rcc, RCC};
pub use uart::*;

pub struct Rcc;

impl Deref for Rcc {

    type Target = rcc::RegisterBlock;

    fn deref(&self) -> &Self::Target {
        unsafe { &*RCC::PTR }
    }
}

